package com.livestocksolutions;

/* -- Version History --
 *  1.0 : 10 July 2012 - Initial version.
 *
 *  1.1 : 16 July 2012 - Class now implements Serializable
 */

/**
 * This class contains data for a Phone number contact.
 *  
 * @author Adam Parr
 * @version 1.1
 * 
 * @.modified 10 July 2012
 */
public class ContactPhone extends ContactDetail {
	/**
	 * Version number of class and value to determine un-serialised class compatibility
	 */
	private static final long serialVersionUID = 11L;
	
	/**
	 * Constructor
	 */
	public ContactPhone(){
		super();
		type="Phone";
	}
	
	/**
	 * Get the phone number for this object 
	 * @return number phone number
	 */
	public String getNumber(){
		return value;
	}
	
	/**
	 * Sets the phone number to the passed String
	 * @param number
	 */
	public void setNumber(String number){
		//TODO do we want to check that the phone number is a valid type here?
		value=number;
	}
	
	@Override
	public String  getValue(){
		//TODO decide if this is the format we want to return in this case, or something different.
		return value;
	}
}
